<!DOCTYPE html>
<html class="x-admin-sm">
<head>
<meta charset="UTF-8">
<title></title>
<meta name="renderer" content="webkit">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width,height=device-height,initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no">
<link rel="stylesheet" href="__ADMIN__/css/font.css">
<link rel="stylesheet" href="__ADMIN__/css/xadmin.css">
<script type="text/javascript" src="__ADMIN__/js/jquery.min.js"></script>
<script type="text/javascript" src="__ADMIN__/lib/layui/layui.js" charset="utf-8"></script>
<script type="text/javascript" src="__ADMIN__/js/xadmin.js"></script>
<script type="text/javascript" src="__ADMIN__/js/cookie.js"></script>
<link rel="stylesheet" href="/static/admin/css/font.css">
<link rel="stylesheet" href="/static/admin/css/font-awesome.min.css">
<style>
.layui-form-item .layui-form-label{
    width: 120px;
}
.layui-form-item .layui-textarea{
    width: 190px;
}
#phone-one-div {display: none}
.layui-form-select {z-index: 99999 !important}
</style>
</head>

<body>
<div class="x-body">
<form class="layui-form" action="">
<fieldset class="layui-elem-field layui-field-title" style="margin-top: 50px;">
  <legend>活动基本信息</legend>
</fieldset> 
 
<table class="layui-table" lay-size="sm">
  <colgroup>
    <col width="200">
    <col>
  </colgroup>
  <tbody>
    <tr>
      <td>活动名称</td>
      <td>{$data.activity_name}</td>
    </tr>
    <tr>
      <td>活动日期</td>
      <td>{:date('Y-m-d',$data.activity_start_time)} - {:date('Y-m-d',$data.activity_end_time)}</td>
    </tr>
    <tr>
      <td>活动时间</td>
      <td>{:date('H:i:s',$data.activity_start_time)} - {:date('H:i:s',$data.activity_end_time)}</td>
    </tr>
    <tr>
      <td>活动地区</td>
      <td>{$data.province}{$data.city}{$data.county}</td>
    </tr>
    <tr>
      <td>活动场馆</td>
      <td>{$data.activity_venues}</td>
    </tr>
    <tr>
      <td>活动地址</td>
      <td>{$data.activity_address}</td>
    </tr>
    <tr>
      <td>设备需求</td>
      <td>{$data.activity_need_device}</td>
    </tr>
    <tr>
      <td>外请直播联系人</td>
      <td>{$data.liveer_name}</td>
    </tr>
    <tr>
      <td>外请直播联系电话</td>
      <td>{$data.liveer_phone}</td>
    </tr>
    <tr>
      <td>价格</td>
      <td>{$data.liveer_price}</td>
    </tr>
    <tr>
      <td>价格</td>
      <td>{$data.liveer_price}</td>
    </tr>
    
    <tr>
      <td>声音是否清晰</td>
      <td><div id="rate1"></div><input type="hidden" lay-verify="required" required name="rate_1" id="rate_1"> </td>
    </tr>
    <tr>
      <td>直播画面流畅度</td>
      <td><div id="rate2"></div><input type="hidden" lay-verify="required" required name="rate_2" id="rate_2"></td>
    </tr>
    <tr>
      <td>服务态度</td>
      <td><div id="rate3"></div><input type="hidden" lay-verify="required" required name="rate_3" id="rate_3"><input type="hidden" lay-verify="required" required name="id" value="{$data.id}"></td>
    </tr>
    <tr>
      <td colspan="2" align="center">    
        <button type="button" class="layui-btn" lay-filter="add" lay-submit="">确定</button>
      </td>
    </tr>
  </tbody>
</table>




</form>
</div>
<script>

    
    
layui.use(['form','layer','laydate','upload','layarea','rate'], function(){
    var $ = layui.jquery;
    var form = layui.form
    ,layer = layui.layer
    ,laydate = layui.laydate
    ,upload = layui.upload
    ,layarea = layui.layarea
    ,rate = layui.rate;

    {for start="1" end="4"}
    rate.render({
        elem: '#rate{$i}'
        ,value: 0
        ,half: true
        ,text: true
        ,setText: function(value){
            this.span.text(value*20+'分');
        }
        ,choose: function(value){
            $('#rate_{$i}').val(value*20);
        }
    });
    {/for}
    form.on('submit(add)', function(data){
        if(!$('#rate_1').val() && !$('#rate_2').val() && !$('#rate_3').val() )
            return;
        $.ajax({
            type:'POST',
            dataType:'json',
            data:data.field,
            url:'{:url('liveProcessAdd')}?id={$data.id}',
            success:function(obj){
                  layer.alert(obj.msg, {icon: obj.icon},function(){
                    // 获得frame索引
                    var index = parent.layer.getFrameIndex(window.name);
                    //关闭当前frame
                    parent.layer.close(index);
                    // 可以对父窗口进行刷新 
                    x_admin_father_reload();
                  });    
            }
        });
        return false;
    });

});
    </script>
  </body>

</html>